package io.shallwe._admin.account;

import com.jfinal.core.Controller;
import com.jfinal.kit.Ret;
import com.jfinal.validate.Validator;

/**
 * @author: gkw
 * @description: io.shallwe._admin.account
 * @date:2019/6/16
 **/
public class PersonalCenterValudator extends Validator {
    @Override
    protected void validate(Controller controller) {
        setRet(Ret.fail());
        validateRequired("password","msg","密码不能为空");
        validateRequired("repassword","msg","确认密码不能为空");
    }

    @Override
    protected void handleError(Controller controller) {
        controller.renderJson(getRet());
    }
}
